#ifndef __WIZ_DATATYPE_GRAPH_LINK_HPP__SHANHAOBO_19800429__
#define __WIZ_DATATYPE_GRAPH_LINK_HPP__SHANHAOBO_19800429__

#include "./WizDataTypeGraphForwardDeclare.hpp"

namespace Wiz
{
    namespace DGraph
    {
        namespace Link
        {
            enum eIOType
            {
                eInput,
                eOutput
            }; /// end of enum eIOType

            class Type
            {
            protected:
                Type(::Wiz::DGraph::Node::Ptr Owner, ::Wiz::DGraph::Link::eIOType IO, ::Wiz::Size::In MaxSize);
                virtual ~Type();
            public:
                ::Wiz::Void::Type Break(::Wiz::DGraph::Link::Ptr);
                ::Wiz::Void::Type Clear();
                ::Wiz::Bool::Type Connect(::Wiz::DGraph::Link::Ptr);
            public:
                ::Wiz::DGraph::Node::Ptr        GetOwner()
                {
                    return this->m_Owner;
                };
                ::Wiz::Void::Type               SetOwner(::Wiz::DGraph::Node::Ptr NodePtr)
                {
                    this->m_Owner = NodePtr;
                };
                ::Wiz::Size::Type               GetMaxSize()
                {
                    return this->m_MaxSize;
                };
                ::Wiz::Void::Type               SetMaxSize(::Wiz::Size::In SZ)
                {
                    this->m_MaxSize = SZ;
                };
            public:
                ::Wiz::DGraph::Link::Set::Ref   GetLinkSet()
                {
                    return this->m_Links;
                };
            private:
                ::Wiz::DGraph::Node::Ptr        m_Owner;
                ::Wiz::DGraph::Link::eIOType    m_IOType;
                ::Wiz::Size::Type               m_MaxSize;

                ::Wiz::DGraph::Link::Set::Type   m_Links;
            };

            namespace Input
            {
                class Type : public ::Wiz::DGraph::Link::Type
                {
                    friend class ::Wiz::DGraph::Link::Output::Type;
                protected:
                    typedef ::Wiz::DGraph::Link::Type Super;
                public:
                    Type(::Wiz::DGraph::Node::Ptr Owner = WIZ_NULL, ::Wiz::Size::Type MaxSize = 1);
                    virtual ~Type();
                protected:
                };
            } /// end of namespace Input

            namespace Output
            {
                class Type : public ::Wiz::DGraph::Link::Type
                {
                    friend class ::Wiz::DGraph::Link::Input::Type;
                protected:
                    typedef ::Wiz::DGraph::Link::Type Super;
                public:
                    Type(::Wiz::DGraph::Node::Ptr Owner = WIZ_NULL, ::Wiz::Size::Type MaxSize = ::Wiz::Size::Max);
                    virtual ~Type();
                protected:
                };
            } /// end of namespace Output
        } /// end of namespace Link
    } /// end of namespace DGraph
} /// end of namespace Wiz

#endif /*__WIZ_DATATYPE_GRAPH_LINK_HPP__SHANHAOBO_19800429__*/
